Don't use magic zero height/width argument to gdk_window_clear_area
authorAlexander Larsson <alexl@redhat.com>
Fri, 11 Sep 2009 13:08:14 +0000 (15:08 +0200)
committerAlexander Larsson <alexl@redhat.com>
Fri, 11 Sep 2009 13:08:14 +0000 (15:08 +0200)
This is an undocumented feature that we stopped supporting, and
anyway it likely only ever worked on X anyway.

gtk/gtkclist.c

index 74302d1edbffebed9127e25f3e35de122f354d9d..f09d6b1371b07d4aab27784ef16b749ca36cac27 100644 (file)
@@ -5925,8 +5925,14 @@ draw_rows (GtkCList     *clist,
     }
 
   if (!area)
-    gdk_window_clear_area (clist->clist_window, 0,
-                          ROW_TOP_YPIXEL (clist, i), 0, 0);
+    {
+      int w, h, y;
+      gdk_drawable_get_size (GDK_DRAWABLE (clist->clist_window), &w, &h);
+      y = ROW_TOP_YPIXEL (clist, i);
+      gdk_window_clear_area (clist->clist_window,
+                            0, y,
+                            w, h - y);
+    }
 }
 
 static void